#include <gflags/gflags.h>
#include "logger.hpp"

DEFINE_int32(run_mode, 0, "程序的运行模式,0-调试,1-发布");
DEFINE_string(log_file, "", "发布模式下,用于指定日志的输出文件");
DEFINE_int32(log_level, 0, "发布模式下,用于指定日志的输出等级");

int main(int argc, char *argv[])
{
    google::ParseCommandLineFlags(&argc, &argv, true);

    init_logger(FLAGS_run_mode, FLAGS_log_file, FLAGS_log_level);

    LOG_DEBUG("Hello {}", "World");
    LOG_INFO("Hello {}", "World");
    LOG_WARN("Hello {}", "World");
    LOG_ERROR("Hello {}", "World");
    LOG_FATAL("Hello {}", "World");
    return 0;
}
